package com.zxc.project.exception;

import com.zxc.project.base.BaseException;

/**
* @author zxc_user
* @date 2021/3/3 21:17
* @version 1.0
* @description 全局异常类枚举     0-199
**/
public enum GlobalExceptionEnum implements BaseException {

    SUCCESS(0, "成功"),
    FAIL(1, "失败"),
    PARAM_ERROR(10, "参数错误")

    ;

    GlobalExceptionEnum(Integer code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    private final Integer code;
    private final String msg;

    @Override
    public Integer getCode() {
        return code;
    }

    @Override
    public String getMsg() {
        return msg;
    }
}
